﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="collaboration_pesonal_reset.aspx.cs" Inherits="Ccit.Mgoa.Collaboration.collaboration_pesonal_reset" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>重新启动协作</title>
    <base target="_self" />
    <script language="javascript" type="text/javascript" src="../script/jsonlib.js"></script>
    <script language="javascript" type="text/javascript">
        function doSave()
        {
            var oFinishDate=document.getElementById("txtFinishDate").value;
            if(oFinishDate=="")
            {
                alert("请选择结束日期！");
                return;
            }
            var oCurDate=new Date().format("yyyy-MM-dd");
            if(oFinishDate<oCurDate)
            {
                alert("终止日期不能小于当前日期！")
                return;
            }
            var oPublishDate=document.getElementById("tdPublishDate").innerHTML;
            if(oFinishDate<oPublishDate)
            {
                alert("终止日期不能小于发布日期！");
                return;
            }
            var oKeepCommentInfo=document.getElementById("chkKeepCommentInfo").checked;
            var oResult=new Array(oFinishDate,oKeepCommentInfo);
            returnValue = oResult;
            window.close();         
        }
        
    </script>
</head>
<body scroll="no" onload="initPage()">
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" EnablePageMethods="true" runat="server"></asp:ScriptManager>
        <input type="hidden" id="hdId" runat="server" />
        <table border="0" cellpadding="0" cellspacing="0" align="center" width="98%" class="tbToolbar">
            <tr>
                <td align="left">
                    <div class="tbSeparator"></div>
                </td>
                <td align="left" class="titlebar" style="width:100%">
                    <nobr>
                        协作管理-重新启动协作
                    </nobr>
                </td>
                <td align="right">
                    <div class="tbSeparatorEnd"></div>
                </td>
            </tr>
        </table>
        <table border="0" cellpadding="0" cellspacing="0" align="center" width="98%" class="tableborder">
            <tr>
                <td class="pformleft" style="width:45%" align="right">
                    发布日期：
                </td>
                <td class="pformright" style="width:55%" align="left" id="tdPublishDate" runat="server"></td>
            </tr>
            <tr>
                <td class="pformleft" align="right">
                    原始终止日期：
                </td>
                <td class="pformright" align="left" id="tdOldFinishDate" runat="server"></td>
            </tr>
            <tr>
                <td class="pformleft" align="right">
                    结束日期：
                </td>
                <td class="pformright" align="left">
                    <nobr>
                        <input type="text" id="txtFinishDate" runat="server" style="width:80px" class="input" />
                        <img src="../images/toolbar/Calendar.gif" alt="结束日期" class="getdate" style="cursor:pointer" relaobj="txtFinishDate" />
                    </nobr>
                </td>
            </tr>
            <tr>
                <td colspan="2" class="pformright">
                    <input type="checkbox" checked id="chkKeepCommentInfo" runat="server" /><label for="chkKeepCommentInfo">保留交流信息</label>
                </td>
            </tr>
            <tr>
                <td colspan="2" align="center" class="pformstrip">
                    <nobr>
                        <input type="button" id="btnSave" runat="server" onclick="return doSave()" value="确定" class="button" />&nbsp;&nbsp;
                        <input type="button" id="btnCancel" onclick="javascript:window.close();" runat="server" value="取消" class="button" />
                    </nobr>
                </td>
            </tr>
        </table>
    </form>
    <script language="javascript" type="text/javascript">
        function initPage()
        {
            var oParam = window.dialogArguments;
            document.getElementById("hdId").value=oParam[0];
            document.getElementById("tdPublishDate").innerHTML=oParam[1];
            document.getElementById("tdOldFinishDate").innerHTML=oParam[2];
        }
    </script>
</body>
</html>
